<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>
<!DOCTYPE html>
<html>
<head>
    <base href="<%=basePath%>">
    <meta charset="UTF-8">
    <title>Insert title here</title>
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet">
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.3.6/css/bootstrap-theme.css" rel="stylesheet">
</head>
<body>
<div class="panel panel-primary">
    <div class="panel-heading">
        <h3 class="panel-title">文件上传示例</h3>
    </div>
</div>
<div class="container">
    <div class="row">
        <div class="col-md-6 col-sm-6">
            <form class="form-horizontal" action="onefile" method="post" enctype="multipart/form-data">
                <div class="form-group">
                    <div class="input-group col-md-6">
							<span class="input-group-addon">
								<i class="glyphicon glyphicon-pencil"></i>
							</span>
                        <input class="form-control" type="text"
                               name="description" placeholder="文件描述"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="input-group col-md-6">
							<span class="input-group-addon">
								<i class="glyphicon glyphicon-search"></i>
							</span>
                        <input class="form-control" type="file"
                               name="myfile" placeholder="请选择文件"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-md-6">
                        <div class="btn-group btn-group-justified">
                            <div class="btn-group">
                                <input type="submit" class="btn btn-success">
                                <span class="glyphicon glyphicon-share"></span>
                                &nbsp;上传文件
                                </input>
                            </div>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
</body>
</html>